<extend name="public/base"/>

<block name="content">
   <!--左侧菜单结束-->
    <!--内容栏start-->
   
    <br/>    
    <ul class="nav nav-tabs">
   <li ><a href="{:U('Index/index')}">作业设计</a></li>
   <li class="active"><a href="{:U('Index/searchHomework')}">作业查询</a></li>
   <li ><a href="{:U('Index/showHomework')}">作业浏览</a></li>
   </ul>
	<!-- 标题栏 -->
	  
    <h4 class="center">最近作业查询</h4> 
        <div class="form-inline">
        <form method='get' id="form" name="form"  action="{:U('Index/searchHomework')}" >
        <div class="controls">           
           <label class="sr-only" for="grade">年级</label>
            <select name="grade" id="grade" class="span2">
                <option>{$Think.get.grade|default="所有年级"}</option>
                <option >1年级上</option>
                <option >1年级下</option>
                <option >2年级上</option>
                <option >2年级下</option>
                <option >3年级上</option>
                <option >3年级下</option>
                <option >4年级上</option>
                <option >4年级下</option>
                <option >5年级上</option> 
                <option >5年级下</option>
                <option >6年级上</option> 
                <option >6年级下</option> 
                <option >所有年级</option>                      
            </select>
         
           <label class="sr-only" for="subject">科目</label>
            <select name="subject" id="subject" class="span1" >
                <option >语文</option>
                <option >数学</option>
                <option >英语</option>
                <option >科学</option>                   
            </select>
         
           <label class="sr-only" for="week">周次</label>
           <select name="week" id="week" class="span2">
           <option>{$Think.get.week|default="所有周次"}</option>
          <for start="1" end="22">
          <option>第{$i}周</option>
          </for>
          <option >所有周次</option>
         </select> 
          <button type="submit" class="btn btn-success">查询</button>

        </div>
      </form> 
      </div> 
      <hr/>    
  
    <!-- 数据列表 -->
        <div class="data-table table-striped ">
         <table class="table data-table table-bordered">
             <thead>
            <tr class="info">                
                <th class="">序号</th>
                <th class="">年级</th>                        
                <th class="">学科</th>
                <th class="">周次</th>  
                <th class="">日期</th>
                <th class="">内容</th>               

            </tr>
            </thead>
            <tbody>
            <notempty name="list">
                <volist name="list" id="vo">
                <tr>                    
                    <td>{$i} </td>
                    <td>{$vo.grade}</td>
                    <td>{$vo.subject}</td>
                    <td>{$vo.week}</td>
                     <td><span><if condition="($vo.update eq 0)"> &nbsp <else/>
                  {$vo.update|date='Y-m-d',###}</if></span></td>                    
                    <td>{$vo.content}</td>                                              
                    
                </tr>
                </volist>
                <else/>
                <td colspan="8" class="text-center"> aOh! 暂时还没有教师布置本周作业! </td>
                </notempty>
            </tbody>
            </table>
        </div>
	</block>

